# -*- coding:utf-8 -*-

class HandlerEngine:
    def __init__(self, handler):
        self.handlers = []
        pass

    def add_handler(self, handler):
        self.handlers.append(handler)

    def handle(self, data):
        result = None
        for handler in self.handlers:
            result = handler.handle(data)
        return result
